package com.example.shiro.util;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @author lijilong
 * @version 1.0
 * @Description:
 * @CreateDate 2018/7/5 9:54
 */
@ApiModel
public class ApiResult<T> {
    @ApiModelProperty(value = "结果代码", name = "code")
    private int code;
    @ApiModelProperty(value = "结果信息", name = "message")
    private String message;
    @ApiModelProperty(value = "结果数据", name = "data")
    private  T data;

    public int getCode() {
        return code;
    }

    public ApiResult setCode(int code) {
        this.code = code;
        return this;
    }

    public String getMessage() {
        return message;
    }

    public ApiResult setMessage(String message) {
        this.message = message;
        return this;
    }

    public T getData() {
        return data;
    }

    public ApiResult setData(T data) {
        this.data = data;
        return this;
    }
}
